﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Admin.master" AutoEventWireup="true" CodeFile="AddProduct.aspx.cs" Inherits="admin_product_AddProduct" %>
<%@ Register Assembly="CKEditor.NET" Namespace="CKEditor.NET" TagPrefix="CKEditor" %>
<%@ Register src="../usercontrol/category.ascx" tagname="category" tagprefix="uc1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="head" Runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceLeft" Runat="Server">
<uc1:category ID="category1" runat="server" />
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="ContentPlaceHolder1" Runat="Server">

    <script type="text/javascript">

        window.onload = function () {

            CKEDITOR.replace('TextBox1');

        }

 </script>
 <div  class="portlet x9">
                    <div class="portlet-header"><h4>Danh sách sản phẩm</h4></div>
                    <div class="portlet-content">
  <%--<asp:UpdatePanel ID="UpdatePanel1" runat="server">
    <Triggers>
    <asp:PostBackTrigger ControlID="BtnSubmit" />
    </Triggers>
   <ContentTemplate>--%>
        <div class ="pcartborder" style ="border: none; margin: 10px 10px;  height:auto">
             <div class="adrow" style="height: 30px; padding-top: 10px;">
                <asp:Label ID="LblHeader" runat="server" Text="Thông tin chi tiết sản phẩm"></asp:Label>
                    <asp:Literal ID="Lmessage" runat="server" Text=""></asp:Literal>
                <hr />
                <asp:HiddenField ID="hdid" runat="server" Visible = "false"  />
            </div>


             <div class="adrow">
                <div class="adlrow">
                    Danh mục sản phẩm:
                </div>
                <div class="adrrow">
                    <asp:DropDownList ID="Dropcategory" runat="server" Width="180px" 
                        Font-Names = "Tahoma" AutoPostBack="true" 
                        onselectedindexchanged="Dropcategory_SelectedIndexChanged" 
                        DataTextField="Category_Name" DataValueField="Category_Id" >
                    </asp:DropDownList>
                </div>
            </div>
             <div class="adrow">
                <div class="adlrow">
                    Loại sản phẩm :
                </div>
                <div class="adrrow">
                    <asp:DropDownList ID="drlType" runat="server" Width="180px" 
                        Font-Names = "Tahoma" DataTextField="Class_Name" DataValueField="Class_Id" >
                    </asp:DropDownList>
                </div>
            </div>
             <div class="adrow">
                <div class="adlrow">
                   Nhà sản xuất:
                </div>
                <div class="adrrow">
                    <asp:DropDownList ID="Dropbrand" runat="server" Width="180px" 
                        Font-Names = "Tahoma" DataTextField="Brand_Name" DataValueField="Brand_Id" >
                    </asp:DropDownList>
                </div>
            </div>
            
            <%-- <div class="adrow">
                <div class="adlrow">
                  Tình trạng sản phẩm:
                </div>
                <div class="adrrow">
                    <asp:DropDownList ID="dropphanloai" runat="server" Width="180px" Font-Names = "Tahoma" >
                    </asp:DropDownList>
                </div>
            </div>--%>
            
       
             <div class="adrow">
                <div class="adlrow">
                    Tên sản phẩm:
                </div>
                
                <div class="adrrow">
                    <asp:TextBox ID="txtname" runat="server" CssClass="adtextbox" Width="200px" MaxLength="200"></asp:TextBox>
                    &nbsp; &nbsp;
                    <asp:RequiredFieldValidator ID="rfvAuthor" runat="server" ControlToValidate="txtname"
                        ErrorMessage="Chưa nhập tên sản phẩm." Font-Bold="true"></asp:RequiredFieldValidator>
                </div>
            </div>             
             <div class="adrow">
                <div class="adlrow">
                    Đơn vị/số lượng /giá bán: 
                </div>
                <div class="adrrow">
                    <asp:TextBox ID="txtunit" runat="server" CssClass="adtextboxl" MaxLength="8"></asp:TextBox>
                     <asp:TextBox ID="txtquantity" runat="server" CssClass="adtextboxl" MaxLength="8"></asp:TextBox>
                      <asp:TextBox ID="txtprice" runat="server" CssClass="adtextboxl" MaxLength="8"></asp:TextBox>
                    &nbsp; &nbsp;
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" ControlToValidate="txtname"
                        ErrorMessage="Chưa nhập đơn giá." Font-Bold="true"></asp:RequiredFieldValidator>
                </div>
            </div>           
             <div class="adrow">
                <div class="adlrow">
                    Thời gian bảo hàng:
                </div>
                <div class="adrrow">
                    <asp:TextBox ID="txtwaranry" runat="server" CssClass="adtextbox" MaxLength="200"></asp:TextBox>
                    &nbsp; &nbsp;
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" ControlToValidate="txtname"
                        ErrorMessage="" Font-Bold="true"></asp:RequiredFieldValidator>
                </div>
            </div>
            <%-- <div class="adrow">
                <div class="adlrow">
                    Xuất xứ:
                </div>
                <div class="adrrow">
                    <asp:TextBox ID="txtmadein" runat="server" CssClass="adtextbox" MaxLength="200"></asp:TextBox>
                    &nbsp; &nbsp;
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ControlToValidate="txtname"
                        ErrorMessage="Chưa nhập Xuất xứ sản phẩm." Font-Bold="true"></asp:RequiredFieldValidator>
                </div>
            </div>--%>
               <div class="adrow">
                <div class="adlrow">
                  Xếp loại-Đánh giá:
                </div>
                <div class="adrrow" style=" font-weight:bold">
                    <asp:CheckBox ID="cknews" runat="server" Text="Sản phẩm mới" />
                    <br />
                    <asp:CheckBox ID="ckhighlights" runat="server" Text="Sản phẩm nổi bật" />
                
                </div>
            </div>
             <div class="adrow" style="height: 120px;">
                <div class="adlrow">
                    Hình ảnh:
                </div>
                <div class="adrrow">
                    <asp:HiddenField ID="hfImage" runat="server" Visible = "false" />
                    <asp:Image ID="imgPic" runat="server"  CssClass ="pcartoimage" 
                        BorderStyle="Dotted" />
                 </div> 
            </div>
             <div class="adrow"  style ="height: 60px;">
                 <div class="adrrow" style =" margin-left: 200px;">
                    <asp:FileUpload ID="fuImage" runat="server" CssClass="upload" /> <br />
                    Chỉ chấp nhập tập tin .gif, .jpg, .jpeg, png. Dung lượng < 2MB.
                    <asp:RegularExpressionValidator 
	                        ID="RegularExpressionValidator1" 
	                        runat="server" 
	                        ControlToValidate="fuImage" 
	                        ErrorMessage="Không phải file ảnh" 
	                        ValidationExpression= 
                        "^([0-9a-zA-Z_\-~ :\\])+(.jpg|.JPG|.jpeg|.JPEG|.bmp|.BMP|.gif|.GIF|.png|.PNG)$"> 
                    </asp:RegularExpressionValidator>
                </div> 
            </div>
             <div class="adrow">
                <div class="adlrow">
                    Chú thích hình:
                </div>
                <div class="adrrow">
                    <asp:TextBox ID="txttitleimage" runat="server" CssClass="adtextbox" MaxLength="200"></asp:TextBox>
                    &nbsp; &nbsp;
                    
                </div>
            </div>
            
         
             <div class="adrow" style="height: 650px; margin-top:20px;">
               
                  <strong style=" font-weight: bold; font-size:14px"> Chi tiết sản phẩm:</strong>
                    <br />
                    <br />
                    <div class="adrrow" style=" width:100%">
                <CKEditor:CKEditorControl ID="CKEditor1" runat="server" Text='
<table width="100%" border="1" cellpadding="3" cellspacing="0" bordercolor="#e0e0e0" >
  <tr>
    <th width="20%" rowspan="3" scope="row"><div align="left">T&#7893;ng quan </div></th>
    <td width="30%">M&#7841;ng</td>
    <td width="50%">&nbsp;</td>
  </tr>
  
  <tr>
    <td>M&agrave;u s&#7855;c </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>K&iacute;ch th&#432;&#7899;c/Tr&#7885;ng l&#7921;&#417;ng </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <th rowspan="3" scope="row"><div align="left">Hi&#7875;n th&#7883; </div></th>
    <td>Ng&ocirc;n ng&#7919; </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Lo&#7841;i m&agrave;n h&igrave;nh </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>K&iacute;ch th&#432;&#417;c hi&#7879;n th&#7883; </td>
    <td>&nbsp;</td>
  </tr>
  
  <tr>
    <th rowspan="4" scope="row"><div align="left">&#272;&#7863;c &#273;i&#7875;m</div></th>
    <td>Ki&#7875;u chu&ocirc;ng </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Tin nh&#7855;n </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>K&#7871;t n&#7889;i </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>Camera</td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <th rowspan="3" scope="row"><div align="left">L&#432;u tr&#7919; </div></th>
    <td>Danh b&#7841; </td>
    <td>250</td>
  </tr>
  <tr>
    <td>B&#7897; nh&#7899; trong </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Th&#7867; nh&#7899; </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <th rowspan="20" scope="row"><div align="left">Th&ocirc;ng tin kh&aacute;c </div></th>
    <td>T&#7843;i nh&#7841;c </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Rung</td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>GPRS</td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>HSCSD</td>
    <td>-</td>
  </tr>
  <tr>
    <td>EDGE</td>
    <td>-</td>
  </tr>
  <tr>
    <td>3G</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Wlan</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>H&#7879; &#273;i&#7873;u h&agrave;nh </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>&#272;&#7891;ng h&#7891; </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>B&aacute;o th&#7913;c </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>&#272;&agrave;i FM </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>Tr&ograve; ch&#417;i </td>
    <td>c&agrave;i s&#7861;n trong m&aacute;y </td>
  </tr>
  <tr>
    <td>Tr&igrave;nh duy&#7879;t </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Java</td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Quay phim </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Ghi &acirc;m </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <td>Nghe nh&#7841;c </td>
    <td>Mp3 Player </td>
  </tr>
  <tr>
    <td>Xem phim </td>
    <td>Mp4/Avi</td>
  </tr>
  <tr>
    <td>Ghi &acirc;m cu&#7897;c g&#7885;i </td>
    <td>----</td>
  </tr>
  <tr>
    <td>Loa ngo&agrave;i </td>
    <td>c&oacute;</td>
  </tr>
  <tr>
    <th rowspan="3" scope="row"><div align="left">Pin</div></th>
    <td>Lo&#7841; pin </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Th&#7901;i gian ch&#7901; </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <td>Th&#7901;i gian &#273;&agrave;m tho&#7841;i </td>
    <td>&nbsp;</td>
  </tr>
  <tr>
    <th scope="row"><div align="left">M&ocirc; t&#7843; </div></th>
    <td colspan="2">&nbsp;</td>
  </tr>
</table>' ResizeMaxWidth="700" Height="564px" ResizeMaxHeight="500" ToolbarCanCollapse="False" 
                            ToolbarStartupExpanded="False" ResizeEnabled="False"></CKEditor:CKEditorControl>
                    </div>

            </div>
         
            <div class="adrow">
                <div class="adlrow">
                <asp:Button ID="BtnSubmit" runat="server" CssClass="search_submit" Text="Đồng ý" onclick="BtnSubmit_Click"  />
                </div>
                <div class="adrrow">
                    <asp:Button ID="BtnCancel" runat="server" CssClass="search_submit"  
                        Text=" Trở lại  " CausesValidation="False" onclick="BtnCancel_Click" />
                
                </div>
            </div>
                        
            
             
                        
            
    </div>
    <%--</ContentTemplate>
 </asp:UpdatePanel>--%>
 </div>
 </div>
</asp:Content>

